/**
 * Created with IntelliJ IDEA.
 * Description:
 * User:岁亮亮
 * Date:2024-01-14
 * TIME:14:11
 */
public class Testextend {
    public static void sui(Student student){
       student.goschool() ;
    }

    public static void main(String[] args) {
        Student[] student={new student1("yuan",12),new student2("sui",13) };
        for(Student s:student){
            s.goschool() ;
        }
    }
    public static void main3(String[] args) {
        student1 student1=new student1("yuan",13);
        sui(student1);
        student2 student2=new student2("hui",12);
        sui(student2 );
    }
    public static void main2(String[] args) {
        Student s=new student1("yuan",12);
        s.goschool();
        s.goo();
    }
    public static void main1(String[] args) {
        student1 student1=new student1("sui",13);
        System.out.println(student1.age);
        System.out.println(student1.name );
        System.out.println(student1.ch );
        student1.method();
    }
}
